package com.qys.livesMall.anchor.model.vo.lives.app;

import com.baomidou.mybatisplus.annotation.TableField;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import org.jetbrains.annotations.NotNull;

import java.math.BigDecimal;

@Data
public class GiftListVO implements Comparable<GiftListVO>{

    @Schema(description = "用户id")
    private Long userId;

    @Schema(description = "用户昵称")
    private Long nickName;

    @Schema(description = "用户头像")
    private String userAvatar;

    @Schema(description = "礼物金币量")
    private BigDecimal giftAmount;

    @Override
    public int compareTo(@NotNull GiftListVO o) {
        return o.getGiftAmount().compareTo(this.getGiftAmount());
    }
}
